/*
 * Author: vyouzhi <vyouzhi@163.com>
 * http://www.xda.cn
 *
 * File: link.h
 * Create Date: 2011-07-04 10:24:23
 *
 */
#ifndef LINK_H_
#define LINK_H_

#define MAXDATA 1024*1024*10

typedef  struct client_info{
	int clientSockfd;
	int recvCount;
	int totallen;
	int recvStatus;
	char data[MAXDATA];
	char *recvbuff;
	struct client_info *next;
} cliInfo;

cliInfo *link_init(void);
void link_insert(cliInfo *dist, cliInfo *src);
void link_del(cliInfo *link_head, int csfd);
void link_free(cliInfo *link_head);
cliInfo *link_find(cliInfo *link_head, int csfd);
int link_len(cliInfo *link_head);

#endif /* LINK_H_ */
/* vim: set ts=4 sw=4: */

